//
// api.js
// vue3-element-admin
//
// Created by 区区电脑 on 2023/04/11.
//


import request from "@/request"


// 添加
export function AddStdSampleInfo(data = {}) {
    return request({url: '/api/StdSample/AddStdSampleInfo', method: 'post', data})
}

// 删除
export function DeleteStdSample(params = {}) {
    return request({url: '/api/StdSample/DeleteStdSample', method: 'delete', params})
}

// 修改
export function UpdateStdSample(data = {}) {
    return request({url: '/api/StdSample/UpdateStdSample', method: 'put', data})
}

// 分页
export function GetStdSamplePageList(params = {}, data = {}) {
    return request({url: '/api/StdSample/GetStdSamplePageList', method: 'post', params, data})
}

/**
 * 基础元素
 * @param data
 * @returns {Promise | Promise<unknown> | *}
 * @constructor
 */
export function GetBaseElemList(data = {}) {
    return request({url: '/api/BaseElem/GetBaseElemList', method: 'post', data})
}

/**
 * 标准样品类型
 * @param data
 * @returns {Promise | Promise<unknown> | *}
 * @constructor
 */
export function GetStdSampleTypeList(data = {}) {
    return request({url: '/api/StdSample/GetStdSampleTypeList', method: 'get', data})
}
/**
 * 导入标准样品
 * @param data
 * @returns {Promise | Promise<unknown> | *}
 * @constructor
 */
export function UploadStdSampleFile(data = {}) {
    return request({url: '/api/StdSample/UploadStdSampleFile', method: 'post', data, upload: true})
}